import request from '@/utils/request'

// 查询批发商管理列表
export function listWholesaler(query) {
  return request({
    url: '/system/wholesaler/list',
    method: 'get',
    params: query
  })
}

// 查询批发商管理详细
export function getWholesaler(wholesalerId) {
  return request({
    url: '/system/wholesaler/' + wholesalerId,
    method: 'get'
  })
}

// 新增批发商管理
export function addWholesaler(data) {
  return request({
    url: '/system/wholesaler',
    method: 'post',
    data: data
  })
}

// 修改批发商管理
export function updateWholesaler(data) {
  return request({
    url: '/system/wholesaler',
    method: 'put',
    data: data
  })
}

// 删除批发商管理
export function delWholesaler(wholesalerId) {
  return request({
    url: '/system/wholesaler/' + wholesalerId,
    method: 'delete'
  })
}
